package com.ydl.learning.flink.demo

import com.ydl.learning.flink.demo.mySink.EsUpdateSink
import org.apache.flink.streaming.api.scala.DataStream

/**
 * es sink使用
 *
 * @author ydl
 * @since 2021/10/21
 */
object EsDemo extends Utils {
  def main(args: Array[String]): Unit = {
    val dataStream: DataStream[String] = getSocketTextStream(9999)._2
    dataStream.addSink(new EsUpdateSink)
    streamEnv.execute("es")
  }
}
